cmake_minimum_required(VERSION 3.15)
project(test)
#定义变量
#静态库生成的路径
set(LIBPATH ${CMAKE_CURRENT_SOURCE_DIR}/lib)
#可执行程序的存储目录
set(EXEPATH ${CMAKE_CURRENT_SOURCE_DIR}/bin)
#头文件路径
set(HEADPATH ${CMAKE_CURRENT_SOURCE_DIR}/include)
#库文件名字
set(CALCLIB calc)
set(SORTLIB sort)
#可执行程序名字
set(APPNAME1 app1)
set(APPNAME2 app2)
#设置c++11
set (CMAKE_CXX_STANDARD 11)
#添加子目录
add_subdirectory(calc)
add_subdirectory(sort)
add_subdirectory(demo)
